package cn.lopr.im.android.utils;

import com.github.qcloudsms.SmsSingleSender;
import com.github.qcloudsms.SmsSingleSenderResult;
import com.github.qcloudsms.httpclient.HTTPException;

import org.json.JSONException;

import java.io.IOException;

public class MessageHelper {

    public static void SMS(String phoneNumber, String[] params) {

        SmsSingleSender ssender = new SmsSingleSender(0, "b2111aa09dd36775c62d7c9fa75245e7");

        try {
            SmsSingleSenderResult result = ssender.sendWithParam("86", phoneNumber, 835567
                    , params, "lopr公众号", "", "");
            System.out.println(result);//查看是否出错
        } catch (JSONException | HTTPException | IOException e) {
            e.printStackTrace();
        }

    }

}

